package com.xzy.sms.web.system.service.impl;

import java.util.Map;

import org.springframework.stereotype.Component;

import com.xzy.sms.web.system.entity.Config;
import com.xzy.sms.web.system.service.ConfigKeysConstants;
import com.xzy.sms.web.system.service.interfaces.IBussConfig;

/**
 * 配置项接口业务实现类
 * 
 * @author macong
 * @since 1.0
 * @version 2015-01-13 macong
 */
@Component
public class BussConfig implements IBussConfig {
    
    /**
     * @return 获取所有配置项
     * @see com.comtop.pssz.service.interfaces.IBussConfig#getAllConfig()
     */
    @Override
    public Map<Object, Config> getAllConfig() {
        return ConfigKeysConstants.getConfigInstance();
    }
    
    /**
     * 获取默认值
     * 
     * @param ckey ckey
     * @return def val
     */
    @Override
    public String getDefValue(String ckey) {
        return ConfigKeysConstants.getCnValue(ckey);
    }
    
    /**
     * 获取备注
     * 
     * @param ckey ckey
     * @return remark
     */
    @Override
    public String getRemarks(String ckey) {
        return ConfigKeysConstants.getRemarks(ckey);
    }
    
}
